# Contributor: Michael Pirogov <vbnet.ru@gmail.com>
# Maintainer: Michael Pirogov <vbnet.ru@gmail.com>
pkgname=lua-resty-core
pkgver=0.1.28
pkgrel=0
pkgdesc="New FFI-based API for lua-nginx-module"
url="https://github.com/openresty/lua-resty-core"
# luajit
arch="noarch !riscv64 !loongarch64"
license="BSD-2-Clause"
depends="luajit lua-resty-lrucache"
source="https://github.com/openresty/lua-resty-core/archive/v$pkgver/lua-resty-core-$pkgver.tar.gz"
options="!check"  # FIXME: tests require OpenResty and additional dependencies

package() {
	make install DESTDIR="$pkgdir" LUA_LIB_DIR="/usr/share/lua/common"

	echo 'rock_manifest = {}' > rock_manifest
	install -D -m 644 rock_manifest \
		"$pkgdir"/usr/lib/luarocks/rocks-common/$pkgname/$pkgver-1
}

sha512sums="
0f54f6eec0805ce31091ce11b065b98a3b286ca3523f5eaf8a85bd8ba229c362a90fa464d5b4b68f155b06011ebb071115e16fd35aa3dd33e316e84a7ec43593  lua-resty-core-0.1.28.tar.gz
"
